//
//  Define.h
//  LimitFree
//
//  Created by lijinghua on 15/9/12.
//  Copyright (c) 2015年 lijinghua. All rights reserved.
//

#ifndef LimitFree_Define_h
#define LimitFree_Define_h

#define kScreenSize   [UIScreen mainScreen].bounds.size
#define kScreenWidth  kScreenSize.width
#define kScreenHeight kScreenSize.height

/*
 界面类型
 */
#define kLimitType      @"limited"
#define kReduceType     @"sales"
#define kFreeType       @"free"
#define kHotType        @"hot"
#define kSubjectType    @"subject"

//数据库中记录的类型
#define kCollectionType   @"collectionType"
#define kBrowserType      @"browserType"
#define kDownloadType     @"downloadType"

#define kLimitUrl @"http://iappfree.candou.com:8080/free/applications/limited?currency=rmb&page=%d&category_id=%@"

//http://iappfree.candou.com:8080/free/applications/limited?currency=rmb&page=0&category_id=0
//不写category_id就是全部   0也表示全部

//降价页面接口
#define kReduceUrl @"http://iappfree.candou.com:8080/free/applications/sales?currency=rmb&page=%d&category_id=%@"

//免费页面接口
#define kFreeUrl @"http://iappfree.candou.com:8080/free/applications/free?currency=rmb&page=%d&category_id=%@"

//专题界面接口
//#define kSubjectUrl @"http://iappfree.candou.com:8080/free/special?page=%d&limit=5"
#define kSubjectUrl @"http://1000phone.net:8088/app/iAppFree/api/topic.php?page=%d&number=5"


//热榜页面接口

#define kHotUrl @"http://1000phone.net:8088/app/iAppFree/api/hot.php?page=%d&number=10"

//内网搜索接口 有四个
//限免搜索
#define SEARCH_LIMIT_URL @"http://www.1000phone.net:8088/app/iAppFree/api/limited.php?page=%d&number=20&search=%@"

//免费搜索
#define SEARCH_FREE_URL @"http://www.1000phone.net:8088/app/iAppFree/api/free.php?page=%d&number=20&search=%@"
//降价搜索
#define SEARCH_REDUCE_URL @"http://www.1000phone.net:8088/app/iAppFree/api/reduce.php?page=%d&number=20&search=%@"
//热榜搜索
#define SEARCH_HOT_URL @"http://www.1000phone.net:8088/app/iAppFree/api/hot.php?page=%d&number=20&search=%@"


//千锋内部接口
#define kCateUrl @"http://1000phone.net:8088/app/iAppFree/api/appcate.php"

//详情页面接口
// http://iappfree.candou.com:8080/free/applications/688743207?currency=rmb
#define kDetailUrl @"http://iappfree.candou.com:8080/free/applications/%@?currency=rmb"

//要传一个applicationid


//周边使用应用接口:
//http://iappfree.candou.com:8080/free/applications/recommend?longitude=116.344539&latitude=40.034346
//参数longitude,latitude填写经度和纬度。
#define kNearAppUrl @"http://iappfree.candou.com:8080/free/applications/recommend?longitude=%lf&latitude=%lf"

#endif
